<?php

namespace app\index\controller;

use app\api\model\CircleModel;

class Member
{

    public function __construct()
    {
        $this->memeberId = session('member_id');
        if (empty($this->memberId)) {
            header('Location: /index/index/index/');
        }
    }

    public function index()
    {
        return View::fetch();
    }

    public function getList()
    {
        $page = input('get.page');
        $data = CircleModel::page($page)->limit(20)->order('circle_id desc')->select();
        $count = CircleModel::count();
        foreach ($data as $value){
        }
        output_data_table($data, $count);
    }

}
